home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Collection of Tools & Utilities
/
Collection of Tools and Utilities.iso
/
ada
/
c01lab1.zip
/
SIMLATRS
/
AUTO_TES.A
next >
Wrap
Text File
|
1992-11-11
|
2KB
|
121 lines
with Automobile_Interface; use Automobile_Interface;
with Console;
procedure Auto_Test is
procedure Show_Speed is
begin
Console.Put (" Current Speed: ");
Console.Put (FLOAT(Sensed_Speed), 3, 2);
Console.Put (" MPH");
Console.New_Line;
end Show_Speed;
begin
Console.Put_Line ("Starting Engine");
Turn_On_Engine;
Update; Show_Speed; Update; Show_Speed;
Console.Put_Line ("Accelerating");
Depress_Accelerator_Pedal;
for I in 1..20 loop
Update;
Show_Speed;
end loop;
Console.Put_Line ("Holding Speed");
Hold_Accelerator_Pedal;
for I in 1..5 loop
Update;
Show_Speed;
end loop;
Console.Put_Line ("Accelerating");
Depress_Accelerator_Pedal;
for I in 1..4 loop
Update;
Show_Speed;
end loop;
Console.Put_Line ("Holding Speed");
Hold_Accelerator_Pedal;
for I in 1..5 loop
Update;
Show_Speed;
end loop;
Console.Put_Line ("Releasing Accelerator Pedal");
Release_Accelerator_Pedal;
for I in 1..5 loop
Update;
Show_Speed;
end loop;
Console.Put_Line ("Accelerating");
Depress_Accelerator_Pedal;
for I in 1..10 loop
Update;
Show_Speed;
end loop;
Console.Put_Line ("Depressing Brake Pedal");
Depress_Brake_Pedal;
for I in 1..4 loop
Update;
Show_Speed;
end loop;
Console.Put_Line ("Releasing Brake Pedal");
Release_Brake_Pedal;
for I in 1..2 loop
Update;
Show_Speed;
end loop;
Console.Put_Line ("Accelerating");
Depress_Accelerator_Pedal;
for I in 1..4 loop
Update;
Show_Speed;
end loop;
Console.Put_Line ("Holding Speed");
Hold_Accelerator_Pedal;
for I in 1..5 loop
Update;
Show_Speed;
end loop;
Console.Put_Line ("Coasting");
Release_Accelerator_Pedal;
for I in 1..10 loop
Update;
Show_Speed;
end loop;
Console.Put_Line ("Depressing Brake Pedal");
Depress_Brake_Pedal;
for I in 1..20 loop
Update;
Show_Speed;
end loop;
Console.Put_Line ("Stopping Engine");
Turn_Off_Engine;
Update;
Show_Speed;
end Auto_Test;